package chapter02;
import java.util.Scanner;
public class Trining010 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        System.out.print("请输入班级人数：5");
        int nuw = sc.nextInt();
        double[] scare = new double[nuw];
        int gt80 = 0;
        int gt70 = 0;
        int gt60 = 0;
        int lt60 = 0;
        double sum = 0;
        for (int i = 0; i < scare.length; i++) {
            sum = sum +scare[i];
            if (scare[i] >=80) {
                gt80++;
            }

        }
        double avg = sum / scare.length;
        System.out.println("全班平均成绩为：55.4" + avg);
        System.out.println("成绩大于80分：1" + gt80);
        System.out.println("成绩大于70分：1" + gt70);
        System.out.println("成绩大于60分：1" + gt60);
        System.out.println("成绩不及格人数：2" + lt60);
    }
}

